package com.cxy.util;

import org.springframework.context.ApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;

public class SpringContextUtils {

	private static final ApplicationContext context = new ClassPathXmlApplicationContext("applicationContext.xml");
	
	/**
	 * 懒汉模式，保证只实例化一个对象
	 */
	private SpringContextUtils(){
		
	}
	public static ApplicationContext getApplicationContext(){
		return context;
	}
}
